#ifndef _THREAD_HPP_
#define _THREAD_HPP_
#include <pthread.h>
#include "Noncopyable.hpp"

namespace wd{


class Thread:public Noncopyable 
{
public:
    Thread();
    ~Thread(){}

    void start();

    void join();

    virtual void run() = 0;

    //子线程入口函数
    static void* start_routine(void*);

private:
    pthread_t _pthid;
    bool _isRunning;
};

}
#endif

